package com.ruoyi.ring.service;

import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.ring.domain.RingSleepDetail;
import com.ruoyi.ring.domain.dto.RingSleepDetailInfoDTO;
import com.ruoyi.ring.domain.dto.RingSleepDetailListDTO;
import com.ruoyi.ring.domain.dto.SleepInfoDTO;
import com.ruoyi.ring.domain.dto.VerifyQueryDTO;
import com.ruoyi.ring.domain.vo.*;

import java.util.List;
import java.util.Map;

/**
 * 睡眠详情Service接口
 * 
 * @author liuwp
 * @date 2025-08-18
 */
public interface IRingSleepDetailService 
{
    /**
     * 查询睡眠详情
     * 
     * @param id 睡眠详情主键
     * @return 睡眠详情
     */
    public RingSleepDetail selectRingSleepDetailById(Long id);

    List<Integer> verify(VerifyQueryDTO queryDTO);
    /**
     * 查询睡眠详情列表
     * 
     * @param ringSleepDetail 睡眠详情
     * @return 睡眠详情集合
     */
    public List<RingSleepDetail> selectRingSleepDetailList(RingSleepDetail ringSleepDetail);

    /**
     * 根据业务主键查询一条记录：睡眠详情
     *
     * @param ringSleepDetail 睡眠详情
     * @return 睡眠详情
     */
    public RingSleepDetail selectOneRingSleepDetail(RingSleepDetail ringSleepDetail);

    /**
     * 新增睡眠详情
     * 
     * @param ringSleepDetail 睡眠详情
     * @return 结果
     */
    public int insertRingSleepDetail(RingSleepDetail ringSleepDetail);

    /**
     * 修改睡眠详情
     * 
     * @param ringSleepDetail 睡眠详情
     * @return 结果
     */
    public int updateRingSleepDetail(RingSleepDetail ringSleepDetail);

    /**
     * 修改睡眠详情
     *
     * @param ringSleepDetail 睡眠详情
     * @param ringSleepDetail 睡眠详情条件
     * @return 结果
     */
    public int updateRingSleepDetailCondition(RingSleepDetail ringSleepDetail, RingSleepDetail ringSleepDetailCondition);

    /**
     * 批量删除睡眠详情
     * 
     * @param ids 需要删除的睡眠详情主键集合
     * @return 结果
     */
    public int deleteRingSleepDetailByIds(Long[] ids);

    /**
     * 删除睡眠详情信息
     * 
     * @param id 睡眠详情主键
     * @return 结果
     */
    public int deleteRingSleepDetailById(Long id);

    /**
     * 条件删除睡眠详情
     *
     * @param ringSleepDetail 睡眠详情
     * @return 结果
     */
    public int deleteRingSleepDetailByCondition(RingSleepDetail ringSleepDetail);

    /**
     * 新增睡眠详情
     *
     * @param sleepInfo 睡眠信息
     * @return 结果
     */
    public int addDetail(SleepInfoDTO sleepInfo);
    /**
     * 查询日历数据列表-app
     */
    List<CalendarResultVO> queryCalendarList(RingSleepDetailInfoDTO sleepDetailInfoDTO);
    /**
     * 查询睡眠详情列表
     *
     * @param sleepDetailListDTO 睡眠详情
     * @return 睡眠详情集合
     */
    List<RingSleepDetail> queryList(RingSleepDetailListDTO sleepDetailListDTO);

    RingSleepDetailVO queryDayInfo(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    WeekOrMonthInfoVO queryWeekOrMonthInfo(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    RingSleepQualityScoreVO queryQualityScore(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    Map<Integer, RingSleepProportionVO> queryProportion(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    AjaxResult queryShortSleep(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    SleepHomeRateVO queryLongSleepHeartRate(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    SleepHomeRateVO querySleepHrv(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    SleepHomeRateVO querySleepBloodOxygen(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    SleepActivityStatusVO querySleepActivityStatus(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    Map<String,Object> querySleepTrend(RingSleepDetailInfoDTO sleepDetailInfoDTO);

    List<SleepTrendWeekOrMonthVO> querySleepTrendWeekOrMonth(RingSleepDetailInfoDTO sleepDetailInfoDTO);

}
